<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>

</head>
<body>

	<div id=root>
	<input type="button" @click=func1 value="btn1">
	<input type="button" @click=func2 value="btn2">
	
	<h1  >{{msg1}}
	</h1>

</div>
<!-- 	这样取值也可以 -->
<!-- 	<div id=root v-text="msg"></div> -->
<!-- 	<div id=root v-html="msg"></div> -->

    <script src="https://cdn.jsdelivr.net/npm/vue@2.5.16/dist/vue.js"></script>
<style type="text/css">
	[v-cloak]{
		display: none;
	}
</style>
	<script type="text/javascript">
	new Vue({
		el:"#root"
// 		,template:'<h1>hh {{msg}}</h1>'
		,data:{
		
			msg1:"aasas91ddda"
			,fl:null
		}
		,methods:{
			func1:function(){
				if(this.fl){
					this.func2();
					this.fl=null;
				}
				this.fl=setInterval(()=>{
					console.log(this.msg1)	
				var start =this.msg1.substring(0,1);
				var end =this.msg1.substring(1);
				this.msg1=end+start;
				},500)
				
			}
			,func2(){
				clearInterval(this.fl);
			}
		}
		
	})
	</script>
</body>
</html>